# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=hashpump
pkgver=49.314268e
pkgrel=1
pkgdesc='A tool to exploit the hash length extension attack in various hashing algorithms.'
groups=('blackarch' 'blackarch-crypto' 'blackarch-cracker')
arch=('x86_64' 'aarch64')
url='https://github.com/bwall/HashPump'
license=('MIT')
depends=('openssl')
makedepends=('git')
source=("$pkgname::git+https://github.com/bwall/HashPump.git")
sha512sums=('SKIP')

pkgver() {
  cd $pkgname

  echo $(git rev-list --count HEAD).$(git rev-parse --short HEAD)
}


build() {
  cd $pkgname

  make
}

package() {
  cd $pkgname

  install -dm 755 "$pkgdir/usr/bin"

  make INSTALLLOCATION="$pkgdir/usr/bin" install

  install -Dm 644 LICENSE.TXT "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}

